package com.fanshuai2.niuke.strings;

import java.util.*;

public class ProcessCommand {
    static String process(String command) {
        Map<String, String> map = new LinkedHashMap<>();
        map.put("reset", "reset what");
        map.put("reset board", "board fault");
        map.put("board add", "where to add");
        map.put("board delete", "no board at all");
        map.put("reboot backplane", "impossible");
        map.put("backplane abort", "install first");
        map.put("he he", "unknown command");

        String unknown = "unknown command";
        List<String> keys = new ArrayList<>();
        if (!command.contains(" ")) {

            for (String key : map.keySet()) {
                if (!key.contains(" ") && key.startsWith(command)) {
                    keys.add(key);
                }
            }

        } else {
            String[] commandArr = command.split(" ");
            for (String key : map.keySet()) {
                if (key.contains(" ")) {
                    String[] arr = key.split(" ");
                    if (arr[0].startsWith(commandArr[0])
                            && arr[1].startsWith(commandArr[1])) {
                        keys.add(key);
                    }
                }
            }
        }
        if (keys.size() == 0 || keys.size() >= 2) {
            return unknown;
        } else {
            return map.get(keys.get(0));
        }
    }
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);

        while (in.hasNextLine()) {
            String command = in.nextLine();
            System.out.println(process(command));
        }
    }
}
